<template>
  <div class="app-category">
    <el-card header="News | 资讯" shadow="never">
      <el-menu :default-active="$route.path" class="app-side-menu" router>
        <el-menu-item index="/news">全部</el-menu-item>
        <el-menu-item v-for="c in data" :id="`ui-side-${c?.id}`" :key="c.id" :index="`/news/category/${c.id}`">
          <span>{{ c.colTitle }}</span>
        </el-menu-item>
      </el-menu>
    </el-card>
  </div>
</template>
<script setup lang="ts">
interface IProps {
  data: any
}

const props = withDefaults(defineProps<IProps>(), {
  data: [],
})
const { data }: any = toRefs(props)
</script>
<style></style>
